package fmanager.kloon.dainb.filemanager;

import com.slidingmenu.lib.SlidingMenu;
import android.os.Bundle;

import com.actionbarsherlock.view.Window;
import com.slidingmenu.lib.app.SlidingFragmentActivity;

public class MainActivity extends SlidingFragmentActivity {

	@Override
	public void onCreate(Bundle savedInstanceState) {
		//		super.onCreate(savedInstanceState);
		//		setContentView(R.layout.activity_main);
		setTheme(com.actionbarsherlock.R.style.Theme_Sherlock_Light);
		super.onCreate(savedInstanceState);
		this.requestWindowFeature(Window.FEATURE_NO_TITLE);
		StartUp();

	}

	// Define LayoutSliding
	private SlidingMenu sliding_menu;
	private int leftLayout;
	private int centerLayout;
	private int rightLayout;
	private void StartUp(){
		leftLayout = R.layout.activity_sliding_left;
		centerLayout = R.layout.activity_main;
		rightLayout = R.layout.activity_sliding_right;
		sliding_menu = getSlidingMenu();
		sliding_menu.setShadowWidthRes(R.dimen.shadow_width);
		sliding_menu.setShadowDrawable(R.drawable.shadow);
		sliding_menu.setBehindOffsetRes(R.dimen.slidingmenu_offset);
		sliding_menu.setFadeDegree(0.35f);
		sliding_menu.setTouchModeAbove(SlidingMenu.TOUCHMODE_FULLSCREEN);
		sliding_menu.setMenu(leftLayout);
		// Main view layout for the activity
		setContentView(centerLayout);
		// set the Behind View
		setBehindContentView(leftLayout);
		getSlidingMenu().setSecondaryMenu(rightLayout);
		getSlidingMenu().setMode(SlidingMenu.LEFT_RIGHT);
		getSlidingMenu().setTouchModeAbove(SlidingMenu.TOUCHMODE_MARGIN);
		getSlidingMenu().setSecondaryShadowDrawable(R.drawable.shadowright);
	}
	@Override
	public void onBackPressed() {
		// TODO Auto-generated method stub
		//	super.onBackPressed();
	}

}
